package day14;

public class TestStringBuffer {
    public static void main(String[] args){
        StringBuffer buffer = new StringBuffer();
        String str = "god";
        char[] data  = str.toCharArray();
//        for(char x : data){
//            buffer.append(x);
//        }
        for(int i = 0; i < data.length; i ++){
            buffer.insert(i, data[i]);
        }
        System.out.println(buffer);
    }
}
